package com.wash.shoes.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.wash.shoes.entity.QualityInspectionPo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

/**
 * 质检Mapper
 */
@Mapper
public interface QualityInspectionMapper extends BaseMapper<QualityInspectionPo> {
    
    /**
     * 根据订单号查询质检数量
     *
     * @param orderId
     * @return
     */
    @Select("select count(1) from os_quality_inspection where order_id = #{orderId} and status='1'")
    int queryCountByOrderId(String orderId);
}
